package com.jinxiangyang.service;

import com.jinxiangyang.domain.vo.FileChunkDTO;
import com.jinxiangyang.domain.vo.FileChunkResultDTO;

import java.io.IOException;

/**
 * @author jinxiangyang
 * @date 2023/8/18 9:53
 * @description TODO
 **/
public interface IUploadService {



    FileChunkResultDTO checkChunkExist(FileChunkDTO chunkDTO);


    /**
     * 上传文件分片
     * @param chunkDTO
     */
    void uploadChunk(FileChunkDTO chunkDTO) throws IOException;


    /**
     * 合并文件分片
     * @param identifier
     * @param fileName
     * @param totalChunks
     * @return
     * @throws IOException
     */
    FileChunkResultDTO mergeChunk(String identifier,String fileName,Integer totalChunks)throws IOException;
}
